Skip to content

Fix documentation errors in Org.Apache.Http.Message, Params, Protocol, Util (R119, pass 3) - #1998

Merged
jonathanpeppers merged 3 commits into
mainfrom
jonathanpeppers-review-org-apache-http-r119
Nov 28, 2026
Merged

jonathanpeppers merged 3 commits into
mainfrom
jonathanpeppers-review-org-apache-http-r119

Conversation

@jonathanpeppers

@jonathanpeppers jonathanpeppers commented Nov 28, 2026 •

Copy link
Copy Markdown
Member

Agent assessment

Self-reported assessment, not an independent review.

Assessed revision: b955f2129e79e3fcd6167f316fa01e3afc723be4

Dimension Assessment Rationale
Change confidence 9/10 ↑ Each of the 9 one-line changes is proved by pinned AOSP apache-http or dotnet/android source lines.
↑ The changed XML parses, git diff --check is clean, and no placeholders were added.
↑ The ledger has one row with a stated claim and a pinned source line for each of the 814 channels.
↑ The gemini-4-argon rubber-duck review of b955f212 found no issues.
↑ The Copilot review of b955f212 recommends approval with no open issues.
↓ The dalexsoto review is pending.
↓ The other 805 channels were judged correct by hand review; a missed error is still possible.

Pass-3 review of AI-authored documentation in Org.Apache.Http.Message, Org.Apache.Http.Params, Org.Apache.Http.Protocol and Org.Apache.Http.Util (81 files, 814 AI-changed channels, including 2 summaries changed by this PR). Every channel was judged against pinned sources. The review found 9 errors and 0 uncertain rows.

Pinned sources: AOSP platform/external/apache-http @ bc93e034 and dotnet/android @ 9bc18c75 (src/Mono.Android).

Fixes

  • HeaderGroup.Iterator(String) returns: the text did not state the name filter. The iterator returns only headers with the specified name, and a null name gives all headers (HeaderGroup.java:279-281, BasicListHeaderIterator.java:135-142).
  • AbstractHttpMessage.HeaderIterator() and HeaderGroup.Iterator() summaries: the old tool-generated text said these parameterless methods return headers with a given name. Each now uses the pinned Javadoc for the parameterless method (HttpMessage.java:166, HeaderGroup.java:259). Without this change, the summary contradicted the corrected returns text.
  • AbstractHttpMessage.HeaderIterator() returns: the text said "matching headers", but this overload has no filter and returns all headers (AbstractHttpMessage.java:147-149, HeaderGroup.java:265-267).
  • BasicHeaderValueParser.ParseElements(CharArrayBuffer, ParserCursor) returns: the text said "All parsed header elements", but elements that have an empty name and no value are dropped (BasicHeaderValueParser.java:131).
  • IHeaderValueParser.ParseElements(CharArrayBuffer, ParserCursor) returns: same "All parsed header elements" claim on the interface. The interface does not promise this, and its implementation drops empty elements (BasicHeaderValueParser.java:131).
  • HttpDateGenerator.CurrentDate value: the text said the value is null if no text has been generated. getCurrentDate formats text on the first call because dateAsLong starts at 0 (HttpDateGenerator.java:67, :78-80).
  • transfer parameter of the (IntPtr, JniHandleOwnership) constructors of BasicHeaderValueParser and BasicNameValuePair: the text said ownership transfers to the instance. The peer makes its own reference; transfer selects deletion of the incoming reference and peer registration (dotnet/android Object.cs:110-118, JNIEnv.cs:360-393). The wording is the same as in Fix documentation errors in Android.App.PermissionUI (R060, pass 3) #1941.

- HeaderGroup.Iterator(String): returns covers the name filter.
- AbstractHttpMessage.HeaderIterator(): returns covers all headers.
- BasicHeaderValueParser.ParseElements: returns notes empty elements are skipped.
- BasicHeaderValueParser and BasicNameValuePair: correct the transfer parameter.

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Copilot AI balanced review requested due to automatic review settings November 28, 2026 18:00
@jonathanpeppers
jonathanpeppers enabled auto-merge (squash) November 28, 2026 18:00

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟢 Approval recommended

No active review issues are recorded for this documentation-only clarification of existing API behavior.

No open issues 🎉

What changed in this PR

This PR corrects five documentation statements across four Org.Apache.Http.Message API files. It clarifies existing behavior without changing API signatures or runtime code.

Changes:

  • Clarifies filtered header iteration, including null-name behavior, and unfiltered iteration over all headers.
  • Documents that parsing excludes elements with an empty name and no value.
  • Corrects constructor parameter descriptions for JNI reference release and peer registration.
File Description
docs/​xml/​Org.Apache.Http.Message/​HeaderGroup.xml Clarifies name filtering and null-name behavior in iterator return documentation.
docs/​xml/​Org.Apache.Http.Message/​BasicNameValuePair.xml Corrects the JNI ownership parameter description.
docs/​xml/​Org.Apache.Http.Message/​BasicHeaderValueParser.xml Corrects JNI ownership wording and documents excluded parser results.
docs/​xml/​Org.Apache.Http.Message/​AbstractHttpMessage.xml Clarifies that the parameterless iterator returns all message headers.

Review effort: Balanced

IHeaderValueParser.ParseElements: drop 'All'; the interface does not
promise that every element in the buffer is parsed.
HttpDateGenerator.CurrentDate: drop the null clause; getCurrentDate
formats text on the first call because dateAsLong starts at 0.

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟢 Approval recommended

No active review issues are recorded for this documentation-only update to the Apache HTTP API reference.

No open issues 🎉

Review effort: Balanced

@jonathanpeppers

Copy link
Copy Markdown
Member Author

@dalexsoto review

AbstractHttpMessage.HeaderIterator() and HeaderGroup.Iterator() take no
name, but their summaries said they return headers with a given name.
Use the pinned Javadoc: HttpMessage.java:166 and HeaderGroup.java:259.

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟢 Approval recommended

No active review issues require changes.

No open issues 🎉

Review effort: Balanced

@dalexsoto dalexsoto left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewed the HTTP documentation updates against the Apache implementation, JNI handle-ownership behavior, and current target changes. The summaries and return-value descriptions are consistent; no blocking issues found. Static review only; no builds or tests were run.

@jonathanpeppers
jonathanpeppers merged commit dc20f1d into main Nov 28, 2026
4 checks passed
@jonathanpeppers
jonathanpeppers deleted the jonathanpeppers-review-org-apache-http-r119 branch November 28, 2026 18:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants